1. Field of the Invention
This invention relates to two-dimensional (2D) color barcodes, and in particular, it relates to the structure of a two-dimensional color barcode and method for decoding the same.
2. Description of Related Art
Barcode is an optical machine-readable representation of data. A 2D color barcode is formed of small square or rectangular cells arranged in a two-dimensional manner, e.g., in both horizontal and vertical directions, and one color is used for each cell. Different colors represent different data values. The relation between the data capacity of the barcode and the cell number and the number of colors can be expressed asData capacity=(Cell Number)×log2(Num of color representations)A barcode design that uses small cell sizes and more color representations can achieve a relatively high data capacity in a given area. However, various factors limit how small cells can be.
Channel offset of digital printers is an inevitable effect caused by hardware imperfections. Channel refers to the different primary colors used by the printer (e.g. cyan, magenta, yellow, and black or CMYK); channel offset refers to the fact that when pixels having the same position values are printed using different primary colors, the actual position of the printed pixels may not be exactly the same. The offset amount may be global (i.e. the same offset across the entire page) and/or local (i.e. they may be different in different areas of a page). When barcode cells are small, the channel offset effect may affect the result noticeably, causing the space between neighboring cells to vary and cells can even merge into each other.
Also, the color density of a cell depends on the cell area. The color density of a small area is relatively low when compared with that of a large area, which may cause difficulty in color determination for barcode with small cells.
Furthermore, the working conditions of different printers and scanners are variable. Different printers will have different output, so will different scanners. The working conditions may also vary with time, so that the output from one printer or one scanner at different times may also vary.